package com.web.exiaodao.business.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import com.web.webstart.base.util.XaUtil;
import com.wordnik.swagger.annotations.ApiModel;
import com.wordnik.swagger.annotations.ApiModelProperty;
import com.web.webstart.base.entity.BaseEntity;

/**
 * @author eason
 * @ClassName: FavoriteTable
 * @Description: 收藏表定义表
 * @date 2016-11-02 14:21:34
 */
@Entity
@Table(name = "tb_xa_favoritetable")
@ApiModel(value = "收藏表定义表")
public class FavoriteTable extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "收藏对象ID,收藏对象ID（Favorite-ObjectID）")
    private String favoriteObjectId;
    @ApiModelProperty(value = "收藏人员ID,收藏人员ID,用户id")
    private Long userId;
    @ApiModelProperty(value = " 类型（1：机构/住 2：商品 3：游学/旅游 4：玩/学乐 ）,2机构;22住;3商城;4玩;42:作者;游学5;服务公共1;12:家政护理; 13:医疗服务|医疗康复; 14:护理培训|培训义工 15:义工中心")
    private String type;
    @ApiModelProperty(value = "收藏状态,收藏状态；取消收藏，在重新收藏是修改记录")
    private Boolean favoriteState;
    @ApiModelProperty(value = "名称,名称")
    private String favName;
    @ApiModelProperty(value = "图片url,图片url")
    private String favUrl;
    @ApiModelProperty(value = "子标题,子标题")
    private String subName;


    public void setFavoriteObjectId(String favoriteObjectId) {
        this.favoriteObjectId = favoriteObjectId;
    }

    @Column(nullable = true, length = 50)
    public String getFavoriteObjectId() {
        return favoriteObjectId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    @Column(nullable = true, length = 50)
    public Long getUserId() {
        return userId;
    }

    public void setType(String type) {
        this.type = type;
    }

    @Column(nullable = true, length = 50)
    public String getType() {
        return type;
    }

    public void setFavoriteState(Boolean favoriteState) {
        this.favoriteState = favoriteState;
    }

    @Column(nullable = true, length = 1)
    public Boolean getFavoriteState() {
        return XaUtil.getBool(favoriteState);
    }

    public void setFavName(String favName) {
        this.favName = favName;
    }

    @Column(nullable = true, length = 255)
    public String getFavName() {
        return favName;
    }

    public void setFavUrl(String favUrl) {
        this.favUrl = favUrl;
    }

    @Column(nullable = true, length = 255)
    public String getFavUrl() {
        return favUrl;
    }

    public void setSubName(String subName) {
        this.subName = subName;
    }

    @Column(nullable = true, length = 500)
    public String getSubName() {
        return subName;
    }


}
